package com.isoft.entity.tableentity.dfme_gtls;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty;
import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlRootElement;
import com.isoft.utils.CustomDateDeserializer;
import lombok.Data;

import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import java.io.Serializable;
import java.util.Date;

@Data
@JacksonXmlRootElement(localName = "GATE")
@XmlAccessorType(XmlAccessType.FIELD)
public class DfmeGtlsGate implements Serializable {
    @JacksonXmlProperty(localName = "GTNO")
    private int gtno;
    @JacksonXmlProperty(localName = "ID")
    private int id;
    @JacksonXmlProperty(localName = "CODE")
    private String code;
    @JacksonXmlProperty(localName = "GTAT")
    private String gtat;
    @JacksonXmlProperty(localName = "ESTR")
    @JsonDeserialize(using = CustomDateDeserializer.class)
    @JsonFormat(pattern = "yyyyMMddHHmmss")
    private Date estr;
    @JacksonXmlProperty(localName = "EEND")
    @JsonDeserialize(using = CustomDateDeserializer.class)
    @JsonFormat(pattern = "yyyyMMddHHmmss")
    private Date eend;
    @JacksonXmlProperty(localName = "RSTR")
    @JsonDeserialize(using = CustomDateDeserializer.class)
    @JsonFormat(pattern = "yyyyMMddHHmmss")
    private Date rstr;
    @JacksonXmlProperty(localName = "REND")
    @JsonDeserialize(using = CustomDateDeserializer.class)
    @JsonFormat(pattern = "yyyyMMddHHmmss")
    private Date rend;
    @JacksonXmlProperty(localName = "BTSC")
    private String btsc;
}
